package com.qianying.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.qianying.entity.CustomerContact;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * 客户主要联系人数据访问层
 * @author check
 * @date 2023-10-20
 */
@Mapper
public interface CustomerContactMapper extends BaseMapper<CustomerContact> {
    /**
     * 根据客户ID查询联系人列表
     * @param customerId 客户ID
     * @return 联系人列表
     */
    @Select("SELECT * FROM customer_contact WHERE customer_id = #{customerId}")
    List<CustomerContact> getByCustomerId(Long customerId);
}